<?php 
include("../JO_02_function.php");
include("../JO_01_configuration.php");
$JO_MySQL = new mysqli( $JO_DB_host, $JO_DB_user, $JO_DB_password, $JO_DB_database );
$JO_MySQL -> query( "SET NAMES 'UTF8'" );
$key=isset($_GET['SO_chude'])?$_GET['SO_chude']:"";
if($key!=''){
$sql='Select * from `genre` where `genre`.`delete` is null and `genre`.`key`='.$key;

$result=JO_query($sql);
if($result->num_rows)
$row=$result->fetch_array();

   ?>
  <form method="post" action="JO_05_execution.php" target="JO_integration_asynchronous" />
	<table>
   
   <input type="hidden"						name="JO_query"				value="genre"/>
   <input type="hidden"						name="log"				value="<?=isset($row['log'])?$row['log']:""?>"/>
   <input type="hidden" name="id" value="<?=isset($row['key'])?$row['key']:""?>"   style="width:480px !important"/>			
                 <tr>
                        <th style="vertical-align:middle;width:70px">	<div style="width:60px;float:left">Subject</div>					</th>
                        <td colspan="4">	<div  style="width:424px;float:left;padding-left:0"><input type="text" name="subject" value="<?=isset($row['subject'])?$row['subject']:""?>"   style="width:480px !important"/></div></td>
                        
                    </tr>
                    <tr>
                        <th style="vertical-align:middle;width:70px">	<div style="width:60px;float:left">Key Bugs</div>					</th>
                        <td colspan="4">	<div  style="width:424px;float:left;padding-left:0"><input type="text" name="key_bugs" value="<?=isset($row['key_bugs'])?$row['key_bugs']:""?>"   style="width:480px !important"/></div></td>
                    </tr>
                    <tr>
                        <th style="vertical-align:middle;width:70px">	<div style="width:60px;float:left">subject I18N</div>					</th>
                        <td colspan="4">	<div  style="width:424px;float:left;padding-left:0"><input type="text" name="subject_I18N"  value="<?=isset($row['subject_I18N'])?$row['subject_I18N']:""?>"   style="width:480px !important"/></div></td>
                    </tr>
                     <tbody id="extendcontent" style="display:none;">
                      <tr>
                    	<th style="vertical-align:middle;width:60px">	<div style="width:60px;float:left">Parent</div>					</th>
                        <td colspan="4">	<div  style="width:424px;float:left;padding-left:0"><input type="text" name="parent"  value="<?=isset($row['parent'])?$row['parent']:""?>"   style="width:480px !important"/></div></td>
                    </tr>
                     <tr>
                    	<th style="vertical-align:middle;width:60px">	<div style="width:60px;float:left">Content</div>					</th>
                        <td colspan="4">	<div  style="width:424px;float:left;padding-left:0"><input type="text"  name="Content" value="<?=isset($row['Content'])?$row['Content']:""?>"   style="width:480px !important"/></div></td>
                    </tr>
                     <tr>
                    	<th style="vertical-align:middle;width:60px">	<div style="width:60px;float:left">Content I18N</div>					</th>
                        <td colspan="4">	<div  style="width:424px;float:left;padding-left:0"><input type="text"  name="Content_I18N" value="<?=isset($row['Content_I18N'])?$row['Content_I18N']:""?>"   style="width:480px !important"/></div></td>
                    </tr>
                    
                    <tr>
                    	<th style="vertical-align:middle;width:60px">	<div style="width:60px;float:left">Note</div>					</th>
                        <td colspan="3">	<div  style="width:424px;float:left;padding-left:0"><input type="text" name="note" value="<?=isset($row['note'])?$row['note']:""?>"   style="width:480px !important"/></div></td>
                    </tr>
                    <tr>
                      <th style="vertical-align:middle;width:60px"> <div style="width:60px;float:left">Update</div>
                      </th>
                      <td colspan="4"><div  style="width:424px;float:left;padding-left:0">
                
                          <label><?=isset($row['update'])?$row['update']:""?></label>
                        </div></td>
                    </tr>
                    </tbody>
                    <tr class="trextend">
                    	<th style="vertical-align:middle;width:70px">	<div style="width:60px;float:left"><input  type="button" value="Extend"  id="tab" class="JO_button"   onclick="show();"/></div>					</th>
                    	<td width="246px"><input type="submit" value="Submit"  id="submit" class="JO_button"   style="width:240px !important" /></td>
                        <td style="padding-left:0 !important"><input type="button" value="Cancel"  id="cancel" class="JO_button"   style="width:240px !important" onClick="move();"/></td>
                    </tr>
            
            </table>
              </form>
         <?php   }if($key==''){?>     
                       
    <form method="post" action="JO_05_execution.php" target="JO_integration_asynchronous" />
	<table>
   
   <input type="hidden"						name="JO_query"				value="genre_add"/>
   <input type="hidden" name="id" value="<?=isset($row['key'])?$row['key']:""?>"   style="width:480px !important"/>			
                 <tr>
                        <th style="vertical-align:middle;width:70px">	<div style="width:60px;float:left">Subject</div>					</th>
                        <td colspan="4">	<div  style="width:424px;float:left;padding-left:0"><input type="text" name="subject" value="<?=isset($row['subject'])?$row['subject']:""?>"   style="width:480px !important"/></div></td>
                        
                    </tr>
                    <tr>
                        <th style="vertical-align:middle;width:70px">	<div style="width:60px;float:left">Key Bugs</div>					</th>
                        <td colspan="4">	<div  style="width:424px;float:left;padding-left:0"><input type="text" name="key_bugs" value="<?=isset($row['key_bugs'])?$row['key_bugs']:""?>"   style="width:480px !important"/></div></td>
                    </tr>
                    <tr>
                        <th style="vertical-align:middle;width:70px">	<div style="width:60px;float:left">subject I18N</div>					</th>
                        <td colspan="4">	<div  style="width:424px;float:left;padding-left:0"><input type="text" name="subject_I18N"  value="<?=isset($row['subject_I18N'])?$row['subject_I18N']:""?>"   style="width:480px !important"/></div></td>
                    </tr>
                     <tbody id="extendcontent" style="display:none;">
                      <tr>
                    	<th style="vertical-align:middle;width:60px">	<div style="width:60px;float:left">Parent</div>					</th>
                        <td colspan="4">	<div  style="width:424px;float:left;padding-left:0"><input type="text" name="parent"  value="<?=isset($row['parent'])?$row['parent']:""?>"   style="width:480px !important"/></div></td>
                    </tr>
                     <tr>
                    	<th style="vertical-align:middle;width:60px">	<div style="width:60px;float:left">Content</div>					</th>
                        <td colspan="4">	<div  style="width:424px;float:left;padding-left:0"><input type="text"  name="Content" value="<?=isset($row['Content'])?$row['Content']:""?>"   style="width:480px !important"/></div></td>
                    </tr>
                     <tr>
                    	<th style="vertical-align:middle;width:60px">	<div style="width:60px;float:left">Content I18N</div>					</th>
                        <td colspan="4">	<div  style="width:424px;float:left;padding-left:0"><input type="text"  name="Content_I18N" value="<?=isset($row['Content_I18N'])?$row['Content_I18N']:""?>"   style="width:480px !important"/></div></td>
                    </tr>
                    
                    <tr>
                    	<th style="vertical-align:middle;width:60px">	<div style="width:60px;float:left">Note</div>					</th>
                        <td colspan="3">	<div  style="width:424px;float:left;padding-left:0"><input type="text" name="note" value="<?=isset($row['note'])?$row['note']:""?>"   style="width:480px !important"/></div></td>
                    </tr>
                    </tbody>
                    <tr class="trextend">
                    	<th style="vertical-align:middle;width:70px">	<div style="width:60px;float:left"><input  type="button" value="Extend"  id="tab" class="JO_button"   onclick="show();"/></div>					</th>
                    	<td width="246px"><input type="submit" value="Submit"  id="submit" class="JO_button"   style="width:240px !important" /></td>
                        <td style="padding-left:0 !important"><input type="button" value="Cancel"  id="cancel" class="JO_button"   style="width:240px !important" onClick="move2();"/></td>
                    </tr>
            
            </table>
              </form>      
                       
                       
       <?php    }?>                